package com.gyt.manager.common.enums;

import lombok.Getter;

/**
 * @author v_yantgao
 */

@Getter
public enum LabelLockEnum {
    UNLOCK(0, "unlock"),
    LOCK(1, "lock");

    private Integer value;

    private String desc;

    LabelLockEnum(Integer value, String desc) {
        this.value = value;
        this.desc = desc;
    }

    public static LabelLockEnum check(String isLock) {
        for (LabelLockEnum lockEnum : values()) {
            if (lockEnum.desc.equals(isLock)) {
                return lockEnum;
            }
        }
        return null;
    }
}
